<?php
include_once("includes/config.php");
db_connection();
$username = $_POST["username"];
$email = $_POST["email"];
//$username = "abc";
//$email = "abc";
//run the query to search for the username and password the match
$query = "SELECT * FROM tbl_user WHERE username = '$username' AND email = '$email'";
$result = mysql_query($query) or die("Unable to verify user because : " . mysql_error());
//this is where the actual verification happens
if(mysql_num_rows($result) != 0)
{
	$query = "UPDATE tbl_user SET password = 'e10adc3949ba59abbe56e057f20f883e' WHERE email = '$email'";
	$result = mysql_query($query) or die("Unable to verify user because : " . mysql_error());
	echo e10adc3949ba59abbe56e057f20f883e;  // set new pass 123456
}
else
{
	echo "__failed__"; // for incorrect response
}
db_close();
?> 